package top.xiaoshuaila.moments.utils;

import org.springframework.security.core.context.SecurityContextHolder;
import top.xiaoshuaila.moments.pojo.Users;

public class Usersutils {
    public static Users getuser(){
        return (Users) SecurityContextHolder.getContext().getAuthentication().getPrincipal();
    }
}
